import ajax from '@/utils/ajax'
import dialog from '@/utils/dialog'
import {IMG_URL} from '@/config'

export default function (query) {
  return ajax({
    url: '/f/home/banaer',
    data: query
  }).then(data => {
    const list = data[0].fileUploadList.map(v => ({
      img: IMG_URL + v.fileUrl,
      link: ''
    }))
    return list
  }).catch(msg => dialog.showToast(msg || '请求失败'))
}
